package com.kensure.controller;

import java.util.List;

import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;

import co.kensure.frame.ResultInfo;
import co.kensure.frame.ResultRowsInfo;

import com.kensure.shike.tj.model.YMDZhiBiao;
import com.kensure.shike.tj.service.StatisticsService;

/**
 * 统计接口
 */
@Controller
@RequestMapping(value = "statistic")
public class StatisticController {

	
	@Resource
	private StatisticsService statisticsService;

	/**
	 * 首页
	 */
	@ResponseBody
	@RequestMapping(value = "index.do", method = { RequestMethod.POST, RequestMethod.GET }, produces = "application/json;charset=UTF-8")
	public ResultInfo initsysconfig(HttpServletRequest req, HttpServletResponse rep) {
		List<YMDZhiBiao> list = statisticsService.selectIndex();
		return new ResultRowsInfo(list);
	}
	


}
